﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using IHISCETeim.DAL;
using IHISCETeim.Model;
using IHISCETeim.Library;
using System.Data;
using IHISCETeim.Web;
using System.Configuration;
namespace IHISCETeim.BLL
{
    public class VIPEmailController
    {
        public static SEMailListInfo GetVIPBuyPassEmail(VIPBuyInfo obj)
        {
            SEMailListInfo objEmail = new SEMailListInfo();

            // AgentQltyInfo obj = AgentQltyController.GetByQltyId(QltyId);
            //OUserInfo svrObj = OUserController.GetById(obj.SrvActUserId);
            objEmail.MailTo = AgentConfigController.VIPCustomerBuyPassEmails;
            objEmail.Subject =string.Format("您有来自经销商{0}的VIP客户{1}采购配件换积分申请,采购单号为{2}", obj.AgentName, obj.RealName,obj.DocNum);
            objEmail.Body = string.Format("采购单号:<b>{0}</b><br/>", obj.DocNum);
            objEmail.Body += string.Format("总金额:<b>{0}</b><br/>", obj.DiscTotalMoney);
            objEmail.Body += string.Format("总积分:<br/><b>{0}</b><br/>", obj.TotalPoint);
            objEmail.Body += "<br/>==============================================================================<br/>";
            objEmail.Body += "<br/>请进入经销商终端平台进行处理.<br/>";
            objEmail.Body += "<BR/><BR/>以上内容为 IHISCE 信息平台系统自动发送，请勿回复.";

            return objEmail;
        }
        public static SEMailListInfo GetVIPAgentExchangeAddEmail(VIPAgentExchangeInfo obj)
        {
            SEMailListInfo objEmail = new SEMailListInfo();

            // AgentQltyInfo obj = AgentQltyController.GetByQltyId(QltyId);
            //OUserInfo svrObj = OUserController.GetById(obj.SrvActUserId);
            objEmail.MailTo = AgentConfigController.VIPCustomerBuyPassEmails;
            objEmail.Subject = string.Format("您有来自经销商{0}的积分兑换申请，单号为{1}", obj.AgentName, obj.DocNum);
            objEmail.Body = string.Format("单号:<b>{0}</b><br/>", obj.DocNum);
            objEmail.Body += string.Format("总金额:<b>{0}</b><br/>", obj.TotalMoney);
            objEmail.Body += string.Format("总积分:<br/><b>{0}</b><br/>", obj.TotalPoint);
            objEmail.Body += "<br/>==============================================================================<br/>";
            objEmail.Body += "<br/>请进入经销商终端平台进行处理.<br/>";
            objEmail.Body += "<BR/><BR/>以上内容为 IHISCE 信息平台系统自动发送，请勿回复.";

            return objEmail;
        }

    }
}
